home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / newsgroups / misc.20000217-20000824 / 000461_news@columbia.edu _Thu Aug 17 01:12:56 2000.msg < prev    next >
Internet Message Format  |  2020-01-01  |  2KB

  1. Return-Path: <news@columbia.edu>
  2. Received: from watsun.cc.columbia.edu (watsun.cc.columbia.edu [128.59.39.2])
  3.     by uhaligani.cc.columbia.edu (8.9.3/8.9.3) with ESMTP id BAA15214
  4.     for <kermit.misc@cpunix.cc.columbia.edu>; Thu, 17 Aug 2000 01:12:56 -0400 (EDT)
  5. Received: from newsmaster.cc.columbia.edu (newsmaster.cc.columbia.edu [128.59.59.30])
  6.     by watsun.cc.columbia.edu (8.8.5/8.8.5) with ESMTP id BAA16589
  7.     for <kermit.misc@watsun.cc.columbia.edu>; Thu, 17 Aug 2000 01:12:55 -0400 (EDT)
  8. Received: (from news@localhost)
  9.     by newsmaster.cc.columbia.edu (8.9.3/8.9.3) id BAA27127
  10.     for kermit.misc@watsun.cc.columbia.edu; Thu, 17 Aug 2000 01:06:06 -0400 (EDT)
  11. X-Authentication-Warning: newsmaster.cc.columbia.edu: news set sender to <news> using -f
  12. From: Clarence Dold <dold@yellow.rahul.net>
  13. Subject: Re: Newbie question
  14. Date: 17 Aug 2000 05:04:26 GMT
  15. Organization: a2i network
  16. Message-ID: <8nfroq$n3l$1@samba.rahul.net>
  17. To: kermit.misc@columbia.edu
  18.  
  19. Frank da Cruz <fdc@watsun.cc.columbia.edu> wrote:
  20.  
  21. : Subsequently you found \freplace() (string replacement), not that you need
  22. : it if you specify break/include sets to \fsplit().  
  23.  
  24. Okay, closer all the time.  
  25. I'm running on Linux at the moment, ckermit 7.0.196.
  26. The series of logins from a file is working.  The desired process is
  27. working ;-)
  28.  
  29. Now I'm trying to use the new-found split to get rid of the :23 on the
  30. vline variable.  But I can't figure out how to gracefully discard the
  31. return from the function.
  32.  
  33. #!/usr/bin/kermit +
  34.  
  35.     \fsplit(\%1,&a,:,.)
  36.     echo 0 \&a[0]
  37.     echo 1 \&a[1]
  38.     echo 2 \&a[2]
  39.  
  40.  
  41. $ onesplit 192.168.1.27:telnet
  42. ?Not a command or macro name: "2"
  43. Command stack:
  44.   1. File  : /home/users/cdold/onesplit (line 3)
  45.   0. Prompt: (top level)
  46. 0 2
  47. 1 192.168.1.27
  48. 2 telnet
  49.  
  50. It appears that the "count of elements" being returned from fsplit is being
  51. seen as a command.  I could assign it to a variable, or echo it, but I
  52. don't see how to discard it cleanly.
  53. freplace isn't the proper tool, since Solaris seems to return :telnet in
  54. the vline, and Linux returns :23 in the vline.  Split would be better.
  55.  
  56. -- 
  57. ---
  58. Clarence A Dold - dold@rahul.net
  59.                 - San Jose & Pope Valley (Napa County) CA.